"use strict";
var __extends = (this && this.__extends) || (function () {
    var extendStatics = function (d, b) {
        extendStatics = Object.setPrototypeOf ||
            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
        return extendStatics(d, b);
    };
    return function (d, b) {
        extendStatics(d, b);
        function __() { this.constructor = d; }
        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
})();
/**
 *
 * 1:抽象类不能被实例化,只能被继承
 * 2: 抽象类中不能有具体的方法，只能有`抽象方法`
 * @abstract
 * @class Animal
 */
var Animal = /** @class */ (function () {
    function Animal() {
    }
    return Animal;
}());
var Cat = /** @class */ (function (_super) {
    __extends(Cat, _super);
    function Cat() {
        return _super !== null && _super.apply(this, arguments) || this;
    }
    Cat.prototype.getName = function () {
        return this.name;
    };
    return Cat;
}(Animal));
var cat = new Cat();
cat.name = 'leichao';
// 类可以实现多个接口，但是只能继承一个父类
var Person = /** @class */ (function (_super) {
    __extends(Person, _super);
    function Person() {
        return _super !== null && _super.apply(this, arguments) || this;
    }
    Person.prototype.eat = function () {
        throw new Error("Method not implemented.");
    };
    Person.prototype.speak = function () {
        throw new Error("Method not implemented.");
    };
    // 
    Person.prototype.getName = function () {
        throw new Error("Method not implemented.");
    };
    return Person;
}(Animal));
var a;
(function (a) {
    // 重写 子类重新实现并覆盖父类中的方法
    var Animal = /** @class */ (function () {
        function Animal() {
        }
        return Animal;
    }());
})(a || (a = {}));
